home *** CD-ROM | disk | FTP | other *** search
/ Tech Arsenal 1 / Tech Arsenal (Arsenal Computer).ISO / tek-01 / unzip42.zip / MAKEFILE.CR < prev    next >
Text File  |  1992-03-20  |  22KB  |  556 lines

  1. # ===========================================================================
  2. # Makefile for UnZip, ZipInfo & Ship:  Unix, OS/2 and MS-DOS (MSC NMAKE only)
  3. # Version:  decrypt + (conditionally) inflate
  4. # ===========================================================================
  5. #
  6. #
  7. # INSTRUCTIONS (such as they are):
  8. #
  9. # "make vax"    -- makes UnZip on a VAX 11-780 BSD 4.3 in current directory
  10. #           (or a SysV VAX, or an 8600 running Ultrix, or...)
  11. # "make"    -- uses environment variable SYSTEM to set the type
  12. #           system to compile for.  This doesn't work for some
  13. #           particularly brain-damaged versions of make (VAX BSD,
  14. #           Gould, and SCO Unix are in this group).  If SYSTEM not
  15. #           set, gives instructions on what to try instead.
  16. # "make list"    -- lists all supported systems (targets), including ship
  17. #           and zipinfo targets
  18. # "make wombat" -- Chokes and dies if you haven't added the specifics
  19. #           for your Wombat 68000 (or whatever) to the systems list.
  20. #
  21. # CFLAGS are flags for the C compiler.  LDFLAGS are flags for the loader.
  22. # LDFLAGS2 are more flags for the loader, if they need to be at the end of
  23. # the line instead of at the beginning.
  24. #
  25. # My host (a VAX 11-780 running BSD 4.3) is hereafter referred to as "my host."
  26. #
  27. # My host's /usr/include/sys/param.h defines BSD for me.  You may have to add
  28. # "-DBSD" to the list of CFLAGS for your system.
  29. #
  30. # Some versions of make do not define the macro "$(MAKE)" (my host did not).
  31. # The makefile should now handle such systems correctly, more or less; the
  32. # possible exception to this is if you've used a make command-line option
  33. # (for example, the one which displays the commands which WOULD be executed,
  34. # but doesn't actually execute them).  It probably needs some more tinkering.
  35. # If things still don't work, use "make" instead of "$(MAKE)" in your system's
  36. # makerule.  Or try adding the following line to your .login file:
  37. #   setenv MAKE "make"
  38. # (It didn't help on my host.)
  39. #
  40. # memcpy and memset are provided for those systems that don't have them;
  41. # they're found in misc.c and will be used if -DZMEM is included in the list
  42. # of CFLAGS.  These days ALMOST all systems have them (they're mandated by
  43. # ANSI), but older systems might be lacking.  And at least ONE machine's
  44. # version results in some serious performance degradation...
  45. #
  46. # SCO Unix 3.2.0:  Don't use -Ox with cc (derived from Microsoft 5.1); there
  47. # is a bug in the loop optimization which causes bad CRC's.  [Onno van der
  48. # Linden]
  49. #
  50. # Be sure to test your nice new UnZip; successful compilation does not always
  51. # imply a working program.
  52.  
  53.  
  54. #####################
  55. # MACRO DEFINITIONS #
  56. #####################
  57.  
  58. # Defaults most systems use (use LOCAL_UNZIP in environment to add flags).
  59. # To add inflation:  uncomment INFL_OBJ below or add it to your environment
  60. # as appropriate, and add -DINFLATE to CFLAGS or to LOCAL_UNZIP.  (This
  61. # won't work if you don't have inflate.c, so don't be a goober...)
  62.  
  63. CC = cc
  64. CR = -DCRYPT
  65. CFLAGS = -O -DUNIX $(CR) $(LOCAL_UNZIP)
  66. ZC = -DZMEM
  67. LD = cc
  68. LDFLAGS = -o unzip
  69. LDFLAGS2 = -s
  70. ZL = -o zipinfo
  71. ZL2 = -s
  72. MV = mv
  73. EXE =
  74. O = .o
  75. #INFL_OBJ = inflate.o  -or-  inflate.obj  (pick one)
  76. OBJS = unzip$O crypt$O extract$O file_io$O $(INFL_OBJ)\
  77.    mapname$O match$O misc$O unimplod$O unreduce$O unshrink$O
  78. OS2_OBJS = unzip.obj crypt.obj dosname.obj extract.obj file_io.obj $(INFL_OBJ)\
  79.    mapname.obj match.obj misc.obj unimplod.obj unreduce.obj unshrink.obj
  80. ZI_OBJS = zipinfo$O misc_$O match$O
  81.  
  82. SHELL = /bin/sh
  83.  
  84. # list of supported systems in this version
  85. SYSTEMS1 = 386i 3Bx 7300 amdahl apollo aviion bsd bull coherent convex
  86. SYSTEMS2 = cray cray_cc cyber_sgi dec dnix encore eta gcc_os2 generic
  87. SYSTEMS3 = generic2 gould hk68 hp icc_os2 minix mips msc_dos msc_os2 next
  88. SYSTEMS4 = p_iris pyramid rs6000 rtaix sco sco_dos sco_x286 sequent sgi
  89. SYSTEMS5 = stellar sun sysv tahoe ultrix vax wombat
  90.  
  91. SYS_UTIL1 = ship ship_dos ship_gcc ship_icc ship_os2 ship_sysv zi_dos
  92. SYS_UTIL2 = zi_gcc zi_icc zi_os2 zipinfo 
  93.  
  94. ####################
  95. # DEFAULT HANDLING #
  96. ####################
  97.  
  98. # The below will try to use your shell variable "SYSTEM" as the type system
  99. # to use (e.g., if you type "make" with no parameters at the command line).
  100. # The test for $(MAKE) is necessary for VAX BSD make (and Gould, apparently),
  101. # as is the "goober" (else stupid makes see an "else ;" statement, which they
  102. # don't like).  "goober" must then be made into a valid target for machines
  103. # which DO define MAKE properly (and have SYSTEM set).  Quel kluge, non?
  104. # And to top it all off, it appears that the VAX, at least, can't pick SYSTEM
  105. # out of the environment either (which, I suppose, should not be surprising).
  106. # [Btw, if the empty "goober" target causes someone else's make to barf, just
  107. # add an "@echo > /dev/null" command (or whatever).  Works OK on the Amdahl
  108. # and Crays, though.]
  109.  
  110. default:
  111.     @if test -z "$(MAKE)"; then\
  112.         if test -z "$(SYSTEM)";\
  113.         then make ERROR;\
  114.         else make $(SYSTEM) MAKE="make";\
  115.         fi;\
  116.     else\
  117.         if test -z "$(SYSTEM)";\
  118.         then $(MAKE) ERROR;\
  119.         else $(MAKE) $(SYSTEM) goober;\
  120.         fi;\
  121.     fi
  122.  
  123. goober:
  124.  
  125. ERROR:
  126.     @echo
  127.     @echo\
  128.  "  If you're not sure about the characteristics of your system, try typing"
  129.     @echo\
  130.  '  "make generic".  If the compiler barfs and says something unpleasant about'
  131.     @echo\
  132.  '  "timezone redefined," try typing "make clean" followed by "make generic2".'
  133.     @echo\
  134.  '  One of these actions should produce a working copy of unzip on most Unix'
  135.     @echo\
  136.  '  systems.  If you know a bit more about the machine on which you work, you'
  137.     @echo\
  138.  '  might try "make list" for a list of the specific systems supported herein.'
  139.     @echo\
  140.  '  And as a last resort, feel free to read the numerous comments within the'
  141.     @echo\
  142.  '  Makefile itself.  Have an excruciatingly pleasant day.'
  143.     @echo
  144.  
  145. list:
  146.     @echo
  147.     @echo\
  148.  'Type "make <system>", where <system> is one of the following:'
  149.     @echo
  150.     @echo  "    $(SYSTEMS1)"
  151.     @echo  "    $(SYSTEMS2)"
  152.     @echo  "    $(SYSTEMS3)"
  153.     @echo  "    $(SYSTEMS4)"
  154.     @echo  "    $(SYSTEMS5)"
  155.     @echo
  156.     @echo\
  157.  'Otherwise set the shell variable SYSTEM to one of these and just type "make".'
  158.     @echo\
  159.  'Targets for related utilities (ZipInfo and Ship) include:'
  160.     @echo
  161.     @echo  "    $(SYS_UTIL1)"
  162.     @echo  "    $(SYS_UTIL2)"
  163.     @echo
  164.     @echo\
  165.  'For further (very useful) information, please read the comments in Makefile.'
  166.     @echo
  167.  
  168.  
  169. ###############################################
  170. # BASIC COMPILE INSTRUCTIONS AND DEPENDENCIES #
  171. ###############################################
  172.  
  173. .c$O :
  174.     $(CC) -c $(CFLAGS) $*.c
  175.  
  176. unzip$(EXE):    $(OBJS)
  177.     $(LD) $(LDFLAGS) $(OBJS) $(LDFLAGS2)
  178.  
  179. crypt$O:        crypt.c unzip.h zip.h    # may or may not be in distribution
  180. dosname.obj:    dosname.c        # for OS/2 only
  181. extract$O:      extract.c unzip.h
  182. file_io$O:      file_io.c unzip.h
  183. inflate$O:      inflate.c unzip.h    # may or may not be in distribution
  184. mapname$O:      mapname.c unzip.h
  185. match$O:        match.c unzip.h
  186. misc$O:         misc.c unzip.h
  187. unimplod$O:     unimplod.c unzip.h
  188. unreduce$O:     unreduce.c unzip.h
  189. unshrink$O:     unshrink.c unzip.h
  190. unzip$O:        unzip.c unzip.h
  191.  
  192. clean:
  193.     rm -f $(OBJS) unzip$(EXE)
  194.  
  195.  
  196. ################################
  197. # INDIVIDUAL MACHINE MAKERULES #
  198. ################################
  199.  
  200. # these are the makerules for various systems
  201. # TABS ARE REQUIRED FOR MANY VERSIONS OF "MAKE"!
  202.  
  203.  
  204. # ---------------------------------------------------------------------------
  205. #   Generic targets (can't assume make utility groks "$(MAKE)")
  206. # ---------------------------------------------------------------------------
  207.  
  208. generic:    unzip    # first try if unknown
  209.  
  210. generic2:        # second try if unknown:  hope make is called "make"...
  211.     make unzip CFLAGS="$(CFLAGS) -DBSD"
  212.  
  213. # ---------------------------------------------------------------------------
  214. #   "Normal" group (both big- and little-endian, structure-padding or not):
  215. # ---------------------------------------------------------------------------
  216.  
  217. 386i:        unzip    # sun386i, SunOS 4.0.2 ["sun:" works, too, but bigger]
  218. 3Bx:        unzip    # AT&T 3B2/1000-80; should work on any WE32XXX machine
  219. 7300:        unzip    # AT&T 7300 (M68000/SysV)
  220. apollo:        unzip    # Apollo Domain/OS machines
  221. aviion:         unzip    # Data General AViiONs, DG/UX 4.3x
  222. bull:        unzip    # Bull DPX/2, BOS 2.00.45 (doesn't require -Xk switch)
  223. coherent:    unzip    # Coherent 3.10, Mark Williams C
  224. cray_cc:    unzip    # Cray-2 and Y-MP, using default (possibly old) compiler
  225. dec:        unzip    # DEC 5820 (MIPS RISC), test version of Ultrix v4.0
  226. dnix:        unzip    # 680X0, DIAB dnix 5.2/5.3 (a Swedish System V clone)
  227. encore:        unzip    # Multimax
  228. eta:        unzip    # ETA-10P*, hybrid SysV with BSD 4.3 enhancements
  229. gould:        unzip    # Gould PN9000 running UTX/32 2.1Bu01
  230. hp:        unzip    # HP 9000 series (68020), 4.3BSD or HP-UX A.B3.10 Ver D
  231. hp_ux:        unzip    # (to match zip's makefile entry)
  232. mips:        unzip    # MIPS M120-5(?), SysV R3 [error in sys/param.h file?]
  233. rs6000:        unzip    # IBM RS/6000 under AIX 3
  234. rtaix:        unzip    # IBM RT 6150 under AIX 2.2.1
  235. sco:        unzip    # Xenix/386 (tested on 2.3.1); SCO Unix 3.2.0.
  236. stellar:    unzip    # gs-2000
  237. sun:        unzip    # Sun 4/110, SunOS 4.0.3c; Sun 3 (68020), SunOS 4.0.3
  238. tahoe:        unzip    # tahoe (CCI Power6/32), 4.3BSD
  239. ultrix:        unzip    # VAXen, DEC 58x0 (MIPS guts), DECstation 2100; v4.x
  240. vax:        unzip    # general-purpose VAX target (not counting VMS)
  241.  
  242. # ---------------------------------------------------------------------------
  243. #   BSD group (for timezone structs [struct timeb]):
  244. # ---------------------------------------------------------------------------
  245.  
  246. bsd:        _bsd    # generic BSD (BSD 4.2, Ultrix handled in unzip.h)
  247.  
  248. _bsd:
  249.     $(MAKE) unzip CFLAGS="$(CFLAGS) -DBSD"
  250.  
  251. # ---------------------------------------------------------------------------
  252. #   SysV group (for extern long timezone and ioctl.h instead of sgtty.h):
  253. # ---------------------------------------------------------------------------
  254.  
  255. sysv:        _sysv    # generic SysV
  256. amdahl:        _sysv    # Amdahl (IBM) mainframe, UTS (SysV) 1.2.4 and 2.0.1
  257. sgi:        _sysv    # Silicon Graphics Iris 4D, Irix SysV rel. 3.3.2
  258.  
  259. _sysv:
  260.     $(MAKE) unzip CFLAGS="$(CFLAGS) -DTERMIO"
  261.  
  262. # ---------------------------------------------------------------------------
  263. #   "Unique" group (require non-standard options):
  264. # ---------------------------------------------------------------------------
  265.  
  266. # Enclosed you'll find a context diff for the unzip41 makefile
  267. # which enhances compilation on a convex.  The previous version
  268. # probably worked great a couple of years ago, and would still do
  269. # so if one compiles in our "backward compatible" pcc mode.   The
  270. # following allows it to work better in a modern convexian environment
  271. # (define __STDC__ manually because default compilation mode has
  272. # extensions and thus doesn't do so).  [5 Mar 1992:  -D__STDC__ removed
  273. # for now because of problems with stat.h]
  274. #
  275. #    $(MAKE) unzip CFLAGS="$(CFLAGS) -D__STDC__ -DCONVEX -ext" ...
  276. convex:            # previous version was tested on C200/C400
  277.     $(MAKE) unzip CFLAGS="$(CFLAGS) -DCONVEX -ext"\
  278.      LDFLAGS="$(LDFLAGS) -ext"
  279.  
  280. # Cray-2 and Y-MP, running Unicos 5.1 or 6.0 (SysV + BSD enhancements)
  281. # and Standard (ANSI) C compiler 1.5, 2.0 or 3.0.
  282. cray:
  283.     $(MAKE) unzip CC="scc" LD="scc"
  284.  
  285. # The unzip41 build on a Cyber 910/SGI running Irix v3.3.3 was successful
  286. # with the following change to Makefile:
  287. cyber_sgi:
  288.     $(MAKE) unzip CFLAGS="$(CFLAGS) -I/usr/include/bsd"\
  289.      LDFLAGS="-lbsd $(LDFLAGS)"
  290.  
  291. # OS/2 2.0 (32-bit) with GNU C compiler (emx)
  292. gcc_os2:
  293.     $(MAKE) unzip.exe CC=gcc LD=gcc EXE=.exe\
  294.      OBJS="$(OBJS) dosname.o"\
  295.      CFLAGS="-O -DOS2 -DEMX32 $(CR) $(LOCAL_UNZIP)"\
  296.      LDFLAGS="-s" LDFLAGS2="-los2 -o unzip.exe"
  297.  
  298. # Heurikon HK68 (68010), UniPlus+ System V 5.0, Green Hills C-68000
  299. hk68:
  300.     $(MAKE) unzip CC="gcc" LD="gcc" LDFLAGS="-n $(LDFLAGS)" \
  301.     CFLAGS="-ga -X138 -DUNIX $(CR) $(LOCAL_UNZIP) -Dlocaltime=localti -Dtimezone=timezon"
  302.  
  303. # OS/2 2.0 (32-bit) with IBM C Set/2 compiler
  304. #
  305. file_io2.obj:        # compile this one module without optimization
  306.     $(CC) -c $(CFLAGS) -O- -Fofile_io2.obj file_io.c
  307.  
  308. icc_os2:
  309.     $(MAKE) -nologo unzip.exe CC=icc LD=icc EXE=.exe O=.obj\
  310.      OBJS="$(OS2_OBJS:file_io.obj=file_io2.obj)"\
  311.      CFLAGS="-Q -Sm -O -Gs -DOS2 $(CR) $(LOCAL_UNZIP)"\
  312.      LDFLAGS="-Q" LDFLAGS2="unzip.def -Fe unzip.exe"
  313.  
  314. # Minix 1.5 PC for the 386 with gcc or bcc
  315. minix:
  316.     $(MAKE) unzip CC=gcc CFLAGS="$(CFLAGS) -DMINIX"
  317.  
  318. # PCs (IBM-type), running MS-DOS, Microsoft C 6.00 and NMAKE.  Can't use the
  319. # SYSTEM environment variable; that requires processing the "default:" target,
  320. # which expands to some 200+ characters--well over DOS's 128-character limit.
  321. # "nmake msc_dos" works fine, aside from an annoying message, "temporary file
  322. # e:\ln023193 has been created."  I have no idea how to suppress this, but it
  323. # appears to be benign (comes from the link phase; the file is always deleted).
  324. # The environment variable LOCAL_UNZIP should be set to something appropriate
  325. # if your library uses other than the default floating-point routines; for 
  326. # example, SET LOCAL_UNZIP=-FPi87.  This target assumes the small-model library
  327. # and an 80286 or better.  At present, everything should still fit within the
  328. # 128-character command-line limit (barely); if not, remove the -nologo.  [GRR]
  329. #
  330. msc_dos:
  331.     $(MAKE) unzip.exe\
  332.      CFLAGS="-Ox $(CR) $(LOCAL_UNZIP) -nologo -G2" CC=cl\
  333.      LD=link EXE=.exe O=.obj LDFLAGS="/noi /nol" LDFLAGS2=",unzip;"
  334.  
  335. # The stack size for OS/2 must be increased to 0x1000, i.e. 
  336. # "-F 1000" has to be added to LDFLAGS for msc_os2. Otherwise
  337. # stack overflow occurs, which are only detected if compiled
  338. # with debugging option, i.e. not with -Gs!! Otherwise something
  339. # minor important seems to be overwritten :-)  [K. U. Rommel]
  340. #
  341. # Extra stack causes errors in GRR version ("/st:0x1000"); no problems
  342. # encountered so far without.  EXEHDR /VERBOSE reports 0a00 bytes of
  343. # extra stack already, so maybe the two versions are different... [GRR]
  344. #
  345. # $(LOCAL_UNZIP):  math libraries and/or any other personal or debugging
  346. #                  definitions:  e.g., SET LOCAL_UNZIP=-FPi87 -DDEBUG_STRUC
  347. # $(NOD):  intended to be used as   SET NOD=-link /nod:slibcep   to allow the
  348. #          use of default library names (slibce.lib) instead of protected-mode
  349. #          names (slibcep.lib), but it fails:  MSC adds its own /nod qualifier,
  350. #          and there seems to be no way to override this.  Typical...
  351. #
  352. #msc_os2:        # old Newtware version (may not work)
  353. #    $(MAKE) -nologo unzip.exe CC=cl LD=link EXE=.exe O=.obj\
  354. #      OBJS="$(OBJS) dosname.obj"\
  355. #      CFLAGS="-nologo -Ox -G2s -DOS2 $(CR) $(LOCAL_UNZIP) -Lp"\
  356. #      LDFLAGS="/noi /nol" LDFLAGS2=",unzip,,,unzip.def"
  357. #    bind -nologo unzip.exe -n DOSSETPATHINFO
  358. msc_os2:        # Kai Uwe Rommel version
  359.     $(MAKE) -nologo unzip.exe CC=cl LD=cl EXE=.exe O=.obj\
  360.      OBJS="$(OS2_OBJS)"\
  361.      CFLAGS="-nologo -Ox -G2s -DOS2 $(CR) $(LOCAL_UNZIP)"\
  362.      LDFLAGS="-nologo $(LOCAL_UNZIP) -Lp -F 1000"\
  363.      LDFLAGS2="unzip.def -o unzip.exe $(NOD)"
  364.     bind -nologo unzip.exe -n DOSSETPATHINFO
  365.  
  366. # NeXT 2.x: make the executable smaller.
  367. next:            # 68030 BSD 4.3+Mach
  368.     $(MAKE) unzip LDFLAGS2="-object -s"
  369.  
  370. # I successfully compiled and tested the unzip program (v30) for the
  371. # Silicon Graphics environment (Personal Iris 4D20/G with IRIX v3.2.2)
  372. p_iris:            # Silicon Graphics Personal Iris 4D20
  373.     $(MAKE) unzip CFLAGS="$(CFLAGS) -I/usr/include/bsd -DBSD"\
  374.      LDFLAGS="-lbsd $(LDFLAGS)"
  375.  
  376. # I have finished porting unzip 3.0 to the Pyramid 90X under OSX4.1.
  377. # The biggest problem was the default structure alignment yielding two
  378. # extra bytes.  The compiler has the -q option to pack structures, and
  379. # this was all that was needed.  To avoid needing ZMEMS we could compile in
  380. # the att universe, but it runs slower!
  381. #
  382. pyramid:    # Pyramid 90X, probably all, under >= OSx4.1, BSD universe
  383.     make unzip CFLAGS="$(CFLAGS) -q -DBSD -DZMEM"
  384.  
  385. # SCO cross compile from unix to DOS. Tested with Xenix/386 and
  386. # OpenDeskTop. Should work with xenix/286 as well. (davidsen)
  387. # Note that you *must* remove the unix objects and executable
  388. # before doing this!
  389. #
  390. sco_dos:
  391.     $(MAKE) unzip CFLAGS="-O $(CR) $(LOCAL_UNZIP) -dos -M0" LDFLAGS="-dos"\
  392.      LDFLAGS2="-o unzip.exe"
  393.  
  394. # SCO Xenix/286 2.2.1
  395. sco_x286:
  396.     $(MAKE) unzip CFLAGS="$(CFLAGS) -Ml2" LDFLAGS="$(LDFLAGS) -Ml2"
  397.  
  398. # Sequent Symmetry is a 386 but needs -DZMEM
  399. # This should also work on Balance but I can't test it just yet.
  400. sequent:    # Sequent w/Dynix
  401.     $(MAKE) unzip CFLAGS="$(CFLAGS) -DBSD -DZMEM"
  402.  
  403. # I didn't do this.  I swear.  No, really.
  404. wombat:        # Wombat 68000 (or whatever)
  405.     @echo
  406.     @echo  '    Ha ha!  Just kidding.'
  407.     @echo
  408.  
  409.  
  410. ##################
  411. # SHIP MAKERULES #
  412. ##################
  413.  
  414. # Ship section:  ship comes with the Zip distribution and is more properly
  415. # supported there.  But the following targets should at least get you started
  416. # if for some reason you're only interested in UnZip.  The comments near the
  417. # top of ship.c explain how to use it, and a little further poking around
  418. # should clear up any problems related to things which should be defined but
  419. # aren't, or which shouldn't be defined but are.  As with ZipInfo below, we
  420. # assume *some* competence...
  421.  
  422. _ship:    ship.c $(DEF)
  423.     $(CC) $(CFLAGS) ship.c $(DEF) $(LDFLAGS2)
  424.  
  425. ship:            # most BSD-type systems, by default
  426.     $(MAKE) _ship LDFLAGS2="-s -o ship"
  427.  
  428. ship_sysv:        # not tested; DIRENT used only to determine mailer
  429.     $(MAKE) _ship CFLAGS="$(CFLAGS) -DDIRENT" LDFLAGS2="-s -o ship"
  430.  
  431. ship_dos:        # not tested
  432.     $(MAKE) -nologo _ship CC=cl EXE=.exe\
  433.      CFLAGS="-nologo -Ox $(LOCAL_UNZIP) -G2s -F 2000"\
  434.      LDFLAGS2="-o ship.exe"
  435.  
  436. ship_os2:        # MSC 6.0, 16-bit OS/2
  437.     $(MAKE) -nologo _ship CC=cl EXE=.exe DEF=ship.def\
  438.      CFLAGS="-nologo -Ox $(LOCAL_UNZIP) -G2s -DOS2 -Lp -F 2000"\
  439.      LDFLAGS2="-o ship.exe"
  440.     bind -nologo ship.exe
  441.  
  442. ship_icc:        # IBM C Set/2, 32-bit OS/2
  443.     $(MAKE) -nologo _ship CC=icc EXE=.exe DEF=ship.def\
  444.      CFLAGS="-Q -Sm -O $(LOCAL_UNZIP) -Gs -DOS2"\
  445.      LDFLAGS2="-Fe ship.exe"
  446.  
  447. ship_gcc:        # GNU gcc / emx, 32-bit OS/2
  448.     $(MAKE) _ship CC=gcc LD=gcc EXE=.exe\
  449.      CFLAGS="-O -DOS2" LDFLAGS2="-s -o ship.exe"
  450.  
  451.  
  452. #####################
  453. # ZIPINFO MAKERULES #
  454. #####################
  455.  
  456. # Zipinfo section:  it is assumed here that anyone competent enough to
  457. # wonder about the internal guts of a zipfile is probably also competent
  458. # enough to compile the program without a lot of hand-holding.  If not...
  459. # oh well. :-)
  460.  
  461. zipinfo$O:    zipinfo.c unzip.h
  462.     $(CC) -c $(CFLAGS) $(ZC) zipinfo.c
  463.  
  464. misc_$O:    misc.c unzip.h
  465.     $(MV) misc.c misc_.c
  466.     $(CC) -c $(CFLAGS) $(ZC) -DZIPINFO misc_.c
  467.     $(MV) misc_.c misc.c
  468.  
  469. zipinfo$(EXE):    $(ZI_OBJS)
  470.     $(LD) $(ZL) $(ZI_OBJS) $(ZL2)
  471.  
  472. zi_dos:
  473.     $(MAKE) zipinfo.exe CFLAGS="-Ox -nologo $(LOCAL_UNZIP) -G2" CC=cl\
  474.      LD=link EXE=.exe O=.obj ZL="/noi /nol" ZL2=",zipinfo;" ZC="" MV="ren"
  475.  
  476. #zi_os2:         # GRR (Newtware) version (do not delete!)
  477. #    $(MAKE) -nologo zipinfo.exe CC=cl LD=link EXE=.exe O=.obj\
  478. #     CFLAGS="-nologo -Ox $(LOCAL_UNZIP) -G2s -DOS2 -Lp" ZC="" MV="ren"\
  479. #     ZL="/nol /noi" ZL2=",zipinfo,,,zipinfo.def"
  480. #    bind -nologo zipinfo.exe
  481. zi_os2:         # Kai Uwe Rommel version (do not delete!)
  482.     $(MAKE) -nologo zipinfo.exe CC=cl LD=cl EXE=.exe O=.obj\
  483.      CFLAGS="-nologo -Ox $(LOCAL_UNZIP) -G2s -DOS2" ZC="" MV="ren"\
  484.      ZL="-nologo $(LOCAL_UNZIP) -Lp -Fb" ZL2="zipinfo.def -o zipinfo.exe"
  485.  
  486. zi_icc:            # IBM C Set/2, 32-bit OS/2
  487.     $(MAKE) -nologo zipinfo.exe CC=icc LD=icc EXE=.exe O=.obj\
  488.      CFLAGS="-Q -Sm -O -Gs -DOS2" ZC="" MV="ren"\
  489.      ZL="-Q" ZL2="zipinfo.def -Fe zipinfo.exe"
  490.  
  491. zi_gcc:            # GNU gcc / emx, 32-bit OS/2
  492.     $(MAKE) zipinfo.exe CC=gcc LD=gcc EXE=.exe\
  493.      CFLAGS="-O -DOS2 -DEMX32" ZC="" MV="ren"\
  494.      ZL="-s" ZL2="-o zipinfo.exe"
  495.  
  496.  
  497. ################
  498. # ATTRIBUTIONS #
  499. ################
  500.  
  501. # Thanks to the following people for their help in testing and/or porting
  502. # to various machines (and thanks to the many others who aren't listed
  503. # here but should be):
  504. #
  505. #  (original Unix port:  Carl Mascott <cmascott@world.std.com>)
  506. #  386i:    Richard Stephen <stephen@corp.telecom.co.nz>
  507. #  3Bx:        Bob Kemp <hrrca!bobc@cbnewse.att.com>
  508. #  7300:    Richard H. Gumpertz <rhg@cpsolv.CPS.COM>
  509. #        Greg Roelofs <roelofs@amelia.nas.nasa.gov>
  510. #  amdahl:    Kim DeVaughn <ked01@juts.ccc.amdahl.com>, Greg Roelofs
  511. #  apollo:    Tim Geibelhaus
  512. #  aviion:    Bruce Kahn <bkahn@archive.webo.dg.com>
  513. #  bull:    Matt D'Errico <doc@magna.com>
  514. #  coherent:    David Fenyes <dfenyes@thesis1.med.uth.tmc.edu>
  515. #  convex:    Randy Wright <rwright@convex.com>
  516. #  cray:    Greg Roelofs, Paul Borman <prb@cray.com>
  517. #  cyber_sgi:    Clint Pulley <u001@cs910.cciw.ca>
  518. #  dec:        "Moby" Dick O'Connor <djo7613@u.washington.edu>
  519. #  dnix:    Bo Kullmar <bk@kullmar.se>
  520. #  eta:        Greg Flint <afc@klaatu.cc.purdue.edu>
  521. #  gould:    Onno van der Linden <linden@fwi.uva.nl>
  522. #  hk68:    John Limpert <gronk!johnl@uunet.UU.NET>
  523. #  hp:        Randy McCaskile <rmccask@seas.gwu.edu> (HP-UX)
  524. #        Gershon Elber <gershon@cs.utah.edu> (HP BSD 4.3)
  525. #  icc_os2:    Kai Uwe Rommel <rommel@informatik.tu-muenchen.de>
  526. #  minix:    Kai Uwe Rommel (Minix 1.5)
  527. #  mips:    Peter Jones <jones@mips1.uqam.ca>
  528. #  msc_dos:    Greg Roelofs
  529. #  msc_os2:    Wim Bonner <wbonner@yoda.eecs.wsu.edu>
  530. #        Kai Uwe Rommel, Greg Roelofs
  531. #  next:    Mark Adler <madler@piglet.caltech.edu>
  532. #  p_iris:    Valter V. Cavecchia <root@itnsg1.cineca.it>
  533. #  pyramid:    James Dugal <jpd@usl.edu>
  534. #  rs6000:    Filip Gieszczykiewicz <fmg@smi.med.pitt.edu>
  535. #  rtaix:    Erik-Jan Vens
  536. #  sco:        Onno van der Linden (SCO Unix 3.2.0)
  537. #           Bill Davidsen <davidsen@crdos1.crd.ge.com> (Xenix/386)
  538. #  sco_dos:    Bill Davidsen
  539. #  sco_x286:    Ricky Mobley <ddi1!lrark!rick@uunet.UU.NET>
  540. #  sequent:    Phil Howard <phil@ux1.cso.uiuc.edu>
  541. #  sgi:        Greg Roelofs (Iris 4D/380?)
  542. #  sun:        Onno van der Linden (Sun 4), Greg Roelofs (Sun 3, 4)
  543. #  tahoe:    Mark Edwards <mce%sdcc10@ucsd.edu>
  544. #  ultrix:    Greg Flint (VAX)
  545. #        Michael Graff <explorer@iastate.edu> (DECstation 2100?)
  546. #        Greg Roelofs (DEC 5810)
  547. #        Alex A Sergejew <aas@brain.wph.uq.oz.au>
  548. #  vax:        Forrest Gehrke <feg@dodger.att.com> (SysV)
  549. #        David Kirschbaum <kirsch@usasoc.soc.mil> (BSD 4.3)
  550. #        Jim Steiner <steiner@pica.army.mil> (8600+Ultrix)
  551. #  wombat:    Joe Isuzu <joe@trustme.isuzu.com>
  552. #  zi_dos:    Greg Roelofs
  553. #  zi_icc:    Kai Uwe Rommel
  554. #  zi_os2:    Greg Roelofs, Kai Uwe Rommel
  555. #  zipinfo:    Greg Roelofs
  556.